<?php
require_once BaseUtil::getModulePath("base") . '/models/BaseDao.php';
class ResourcesDao extends BaseDao
{
    protected $_name = 'resources';
    public function getResourceId ($controller)
    {
        $db = $this->db_r;
        $select = $db->select();
        $select->from($this->_name, 'id');
        $select->where('resource_name=?', $controller);
        $sql = $select->__toString();
        return $db->fetchOne($sql);
    }
}
